//
//  DeviceLockIntroduceViewController.m
//  ERP
//
//  Created by QA on 15/9/15.
//  Copyright (c) 2015年 ShangHai HaoLei Software Technology Co., Ltd. All rights reserved.
//

#import "DeviceLockIntroduceViewController.h"
#import "CLLockVC.h"

@interface DeviceLockIntroduceViewController ()

@end

@implementation DeviceLockIntroduceViewController

- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
    self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
    if (self) {
        [self setTitle: @"手势密码锁定"];
    }
    return self;
}

- (void)viewDidLoad {
    [super viewDidLoad];
    
    [self.createButton.layer setCornerRadius:8.0];
    [self.createButton.layer setMasksToBounds:YES];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

- (IBAction)createButtonSelector:(id)sender
{
    [CLLockVC showSettingLockVCInVC:self.navigationController successBlock:^(CLLockVC *lockVC, NSString *pwd) {
        NSLog(@"密码设置成功");
        //[lockVC dismiss:1.0f];
        NSArray *viewControllers = self.navigationController.viewControllers;
        UIViewController *view = [self.navigationController.viewControllers objectAtIndex:(viewControllers.count - 3)];
        [self.navigationController popToViewController:view animated:YES];
    }];
}

@end
